<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
       .container div {
            background-color: aqua;
        }

        .container {
            display: grid;
            grid-template-columns: 100px 400px;
            grid-template-rows: 50px 150px 50px;
            gap: 10px;
        }

        .header {
            grid-area: 1 / 1 / 2 / 3;

            /*1/1 表示起始行起始列  2 / 3 表示该网格项的结束行和结束列*/
        }

        .sidebar {
            grid-column: 1 / 2;
        }

        .content {
            grid-column: 2 / 3;
        }

        .footer {
            grid-column: 1 / 3;
        }
    </style>
</head>

<body>
    <div class="container">
        <div class="header">header</div>
        <div class="sidebar">sidebar</div>
        <div class="content">content</div>
        <div class="footer">footer</div>
    </div>
</body>

</html>